DIR_INC = ./
DIR_SRC = ./

SRC = ./*.cpp

INCLUDE = -I /usr/local/include/mqtt/

TARGET = mq_client
LIB = -L/usr/local/lib/ -lpaho-mqtt3as -lpaho-mqtt3a -lpaho-mqttpp3 -lpthread

CC = g++
CFLAGS = -g -Wall -I${DIR_INC} -std=c++11

${TARGET}:${DIR_SRC}/${SRC}
	$(CC) ${CFLAGS} $^ -o $@ ${INCLUDE} ${LIB}

.PHONY:clean
clean:
	rm  $(TARGET)
